package ModelLayer;

public class Copy
{
    private String serialNumber;
    private String purchaseDate;
    private double purchasePrice;
    private long dvdId;
    private boolean loaned;
    private long loanId;
  

    /**
     * Constructor for objects of class Copy
     */
    public Copy(long dvdId,String serialNumber,String purchaseDate,double purchasePrice)
    {
        this.dvdId=dvdId;
        this.serialNumber=serialNumber;
        this.purchaseDate=purchaseDate;
        this.purchasePrice=purchasePrice;
        loaned=false;
    }
    
    
    
    /**
     * Set and get methods.
     */
    
    public void setSerialNumber(String newSerialNumber){
        
        this.serialNumber=newSerialNumber;
    }
    
    public String getSerialNumber(){
        
        return this.serialNumber;
    }
    
    public long getDVDId()
    {
        return dvdId;
    }
    
    
    
    public void setPurchaseDate(String newdate){
        
        this.purchaseDate=newdate;
    }
    
    public String getPurchaseDate(){
        
        return this.purchaseDate;
    }
    
    
    
    
    public void setPurchasePrice(double price){
        
        this.purchasePrice=price;
    }
    
    public double getPurchasePrice(){
        
        return this.purchasePrice;
    }
    
    public void loanCopy(long loanId)
    {
        this.loanId=loanId;
        loaned=true;
        
    }
    
    public boolean getLoanedState()
    {
        return loaned;
    }
    
    public long getLoanId()
    {
        return loanId;
    }
    
    public void setLoanedState(boolean loaned)
    {
        this.loaned = loaned;
    }
    
    public void setLoanId(long loanId)
    {
        this.loanId = loanId;
    }
    

    
    
  
 
}
